<?php if (!defined('THINK_PATH')) exit(); /*a:1:{s:79:"D:\phpStudy\WWW\qybaowap\public/../application/index\view\user\editusename.html";i:1514275479;}*/ ?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <script src="__STATIC__/js/jquery-1.11.1.min.js"></script>
    <script src="__STATIC__/js/base.js"></script>
    <title>修改用户名</title>
    <link rel="stylesheet" href="__STATIC__/css/base.css">
    <link rel="stylesheet" href="__STATIC__/css/privider.css">
    <link rel="stylesheet" href="__STATIC__/js/layer_mobile/need/layer.css">
    <script src="__STATIC__/js/form_validation.js"></script>
    <script src="__STATIC__/js/layer_mobile/layer.js"></script>
</head>
<body>
<section class="wrap">
    <div  class="privider-form" style="width: 90%;margin: 0 auto;padding-top: 1.2rem">
        <form id="form1">
            <div class="form-content ">
                <div class="clearfix input-inline">
                    <div class="formtitle pull-left" style="width: 2.52rem">姓名：</div>
                    <div class="formcontent pull-left">
                        <input tabindex="1"  id="user_name_a" class="inputstyle1" autocomplete="off" type="text" name="username" placeholder="请输入姓名"/>
                        <span class="success"></span>
                    </div>
                </div>
            </div>
            <input type="button" value="提交" class="privider-button" id="sublimit">
        </form>
    </div>
</section>
<script>
    $(function(){
        //发送短信
        $('#sublimit').on('click',function(){
//            var  res = searchSub();
            var  res = 'ok';
            if(res =='ok'){
                //提交
//                $.ajax({
//                    cache: true,
//                    type: "POST",
//                    url:"",
//                    data:$('#form1').serialize(),// 你的formid
//                    async: false,
//                    error: function(request) {
//                        layer.open({
//                            content:'提交失败'
//                            ,skin: 'msg'
//                            ,time:3 //2秒后自动关闭
//                        });
//                    },
//                    success: function(data) {
//                        if(data.code =='ok'){
//                            //连接不对
//                            window.location.href='/index.html';
//                        }else {
//                            layer.open({
//                                content:data.msg
//                                ,skin: 'msg'
//                                ,time:3 //2秒后自动关闭
//                            });
//                        }
//                    }
//                });
                var url=document.referrer;
                //从订单确认面过来的则是选择收货地址，跳回订单确认页面
                var sear=new RegExp('/setting.html');
                if(sear.test(url)){
                    var name = $("#user_name_a").val();
                    window.location.href= '/setting.html?userName='+name;
                }
            }else{
                //信息框
                //提示
                layer.open({
                    content:res
                    ,skin: 'msg'
                    ,time:3 //2秒后自动关闭
                });
            }
        });
    });
</script>
</body>
</html>